import asyncio
from mcp import MCP

async def main():
    # 获取文档格式化服务
    doc_format_agent = await mcp.get_service("doc_format_agent")
    
    # 格式化单个文档
    result = await doc_format_agent.format_document(
        input_path="input_docs/example.docx",
        output_path="output_docs/formatted_example.docx",
        sample_path="sample_docs/sample.docx"
    )
    print(f"Single document formatting result: {result}")
    
    # 批量格式化文档
    batch_results = await doc_format_agent.format_batch(
        input_dir="input_docs",
        output_dir="output_docs",
        sample_path="sample_docs/sample.docx"
    )
    print(f"Batch processing results: {batch_results}")

if __name__ == "__main__":
    asyncio.run(main())
